package auctions;

import java.util.Vector;

public class BidderResults {

	private Vector<Integer> _itemsWon;
	private double _totalRevenue;
	private double _totalCost;
	private Agent _agent;
	
	public BidderResults(Agent agent) {
   
		_agent = agent;
		_totalRevenue = 0;
		_totalCost = 0;
		_itemsWon = new Vector<Integer>();
	}
	
	public void addWinning(int itemNum, double price) {
        
		_totalRevenue +=_agent.getUtility(itemNum);
		_totalCost+=price;
		_itemsWon.add(itemNum);
	}
	
	public double getRevenue() {
		return _totalRevenue;
	}
	
	public double getCost() {
     
		return _totalCost;
	}
	
	public double getProfit() {
		return _totalRevenue - _totalCost;
	}
	
	public Vector<Integer> getItemsWon() {
		return _itemsWon;
	}
	
}
